<?php
echo $javascript->link('ckeditor/ckeditor');
//$config['toolbar'] = array( 
//    array( 'Bold', 'Italic', 'Underline', 'Strike' ), 
//    array( 'Image', 'Link', 'Unlink', 'Anchor' ) 
//); 
$config['height'] = 300;
?>
<div>
<?php
  echo $cksource->create('Upload',array('url'=>array('plugin'=>'gallery','controller'=>'gallery','action'=>'edit')));
  echo $form->input('Gallery.name');
  echo $form->input('Gallery.youtube');
  echo $cksource->ckeditor('Gallery.content', array( 'config'=>$config));
  echo $form->hidden('Gallery.category_id');
  echo $form->hidden('Gallery.id');
  echo $form->end(__("Save File",true));
?>

<?php echo $fileUpload->image($this->data['Upload']['name'],array('autoResize'=>true,'width'=>500,'imagePathOnly'=>false));?>
</div>